package com.aeon.jface.treeTable.ui;

import java.util.ArrayList;
import java.util.List;

public class Node {

	private String mName;
	private List<Node> mChildren = new ArrayList<>();
	private Node mParent;

	public Node(Node node, String name) {
		mParent=node;
		mName=name;
	}

	/**
	 * @return the mParent
	 */
	public Node getmParent() {
		return mParent;
	}

	/**
	 * @param mParent
	 *            the mParent to set
	 */
	public void setmParent(Node mParent) {
		this.mParent = mParent;
	}

	/**
	 * @return the mName
	 */
	public String getmName() {
		return mName;
	}

	/**
	 * @param mName
	 *            the mName to set
	 */
	public void setmName(String mName) {
		this.mName = mName;
	}

	/**
	 * @return the mChildren
	 */
	public List<Node> getmChildren() {
		return mChildren;
	}

	/**
	 * @param mChildren
	 *            the mChildren to set
	 */
	public void setmChildren(List<Node> mChildren) {
		this.mChildren = mChildren;
	}

	public void addChild(Node node) {
		mChildren.add(node);
	}
	@Override
	public String toString() {
		// TODO Auto-generated method stub
		return mName;
	}
}
